<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="/jquery.js"></script>
</head>
<body>
    <img src="" alt="">
    
    <script>
        // https://www.baidu.com/s?ie=utf-8&f=8
        // url:http协议 + 域名 + 端口号
        // 同源策略,只能在同协议,同域名同端口下才能获取数据,想要获取就会出现跨域问题

        // jsonp一种跨域方式
        // img,a,link,script的src以及href属性都是带有跨域功能(都是get请求)
        // http://192.168.21.6:80/03php.php
        var scr = "<script src='http://192.168.21.6:80/03php.php?callback=fun'><\/script>";
        // document.body.appendChild("一个标签对象")
        $("body").append(scr)

        function fun(res){
            console.log("---",res);
        }
    </script>
</body>
</html>